Routines (alphabetical) > Routines: Q > QUERY_CSV

QUERY_CSV

Syntax | Return Value | Arguments | Keywords | Version History | See Also

The QUERY_CSV function tests a file for compatibility with READ_CSV and returns an optional structure containing information about the file.

This routine is written in the IDL language. Its source code can be found in the file query_csv.pro in the lib subdirectory of the IDL distribution.

Syntax

Result = QUERY_CSV( Filename [, Info] )

Return Value

This routine returns a long with the value of 1 (one) if the query was successful (and the file type was correct) or 0 (zero) on failure.

Arguments

Filename

A scalar string containing the full pathname of the file to query.

Info

A named variable in which to return an anonymous structure containing information about the file. This structure is valid only when the return value of the function is 1. The structure has the following fields:

The Info Argument’s Anonymous Structure

Field

IDL Type

Description

NAME

String

File name, including full path

TYPE

String

File format (always 'CSV')

LINES

Long64

Number of lines

NFIELDS

Long

Number of columns

Keywords

None

Version History

7.1

Introduced

See Also

QUERY_ASCII, READ_ASCII , READ_CSV, WRITE_CSV